-
Notifications
You must be signed in to change notification settings - Fork 25.5k
[ML] RegressionIT: Fix hyperparameters for regression tests and unmute the test #135541
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Pinging @elastic/ml-core (Team:ML) |
Would changing the test so that The way we determine the prediction error also seems like it could be improved, since using the absolute value of the difference between the predicted and actual value is very forgiving for small numbers and very strict for large numbers (being allowed to be off by 3 when the predicted value is 2 is a huge margin of error compared to being allowed to be off by 3 when the predicted value is 600). Perhaps instead of the absolute difference between predicted and actual, the relative difference could be used, since that would allow the final assertion to be that the predictions are on average within some % of the actual value, rather than being within some absolute range. Something like this perhaps (I chose 1% arbitrarily, I don't know how lenient the test actually needs to be):
|
@DonalEvans , thank you for your comment. This is a useful technique, and we employ similar assertions elsewhere in the test, where we actually verify that the algorithm is learning and predicting correct values. The goal of this test is to test that the alias fields are used correctly. Without fixing the hyperparameters on this test, the prediction was (on very rare occasions) completely off, and hence it would fail whether the assertion threshold is expressed in terms of relative or absolute values. |
Thanks for the explanation! |
…e the test (elastic#135541) This PR fixes the flaky test muted in elastic#93228 by fixing hyperparameters to the values that always work. Since the test is for alias fields and not for the training algorithm, fixing the hyperparameters is not dangerous. Closes elastic#93228
…e the test (elastic#135541) This PR fixes the flaky test muted in elastic#93228 by fixing hyperparameters to the values that always work. Since the test is for alias fields and not for the training algorithm, fixing the hyperparameters is not dangerous. Closes elastic#93228
…e the test (elastic#135541) This PR fixes the flaky test muted in elastic#93228 by fixing hyperparameters to the values that always work. Since the test is for alias fields and not for the training algorithm, fixing the hyperparameters is not dangerous. Closes elastic#93228
…e the test (elastic#135541) This PR fixes the flaky test muted in elastic#93228 by fixing hyperparameters to the values that always work. Since the test is for alias fields and not for the training algorithm, fixing the hyperparameters is not dangerous. Closes elastic#93228
This PR fixes the flaky test muted in #93228 by fixing hyperparameters to the values that always work. Since the test is for alias fields and not for the training algorithm, fixing the hyperparameters is not dangerous.
Closes #93228